package com.ruoyi.slope.video.device.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.slope.video.device.mapper.SlopeVideoDeviceMapper;
import com.ruoyi.slope.video.device.domain.SlopeVideoDevice;
import com.ruoyi.slope.video.device.service.ISlopeVideoDeviceService;

/**
 * 视频设备列表Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-09-27
 */
@Service
public class SlopeVideoDeviceServiceImpl implements ISlopeVideoDeviceService 
{
    @Autowired
    private SlopeVideoDeviceMapper slopeVideoDeviceMapper;

    /**
     * 查询视频设备列表
     * 
     * @param id 视频设备列表主键
     * @return 视频设备列表
     */
    @Override
    public SlopeVideoDevice selectSlopeVideoDeviceById(Long id)
    {
        return slopeVideoDeviceMapper.selectSlopeVideoDeviceById(id);
    }

    /**
     * 查询视频设备列表列表
     * 
     * @param slopeVideoDevice 视频设备列表
     * @return 视频设备列表
     */
    @Override
    public List<SlopeVideoDevice> selectSlopeVideoDeviceList(SlopeVideoDevice slopeVideoDevice)
    {
        return slopeVideoDeviceMapper.selectSlopeVideoDeviceList(slopeVideoDevice);
    }

    /**
     * 新增视频设备列表
     * 
     * @param slopeVideoDevice 视频设备列表
     * @return 结果
     */
    @Override
    public int insertSlopeVideoDevice(SlopeVideoDevice slopeVideoDevice)
    {
        return slopeVideoDeviceMapper.insertSlopeVideoDevice(slopeVideoDevice);
    }

    /**
     * 修改视频设备列表
     * 
     * @param slopeVideoDevice 视频设备列表
     * @return 结果
     */
    @Override
    public int updateSlopeVideoDevice(SlopeVideoDevice slopeVideoDevice)
    {
        slopeVideoDevice.setUpdateTime(DateUtils.getNowDate());
        return slopeVideoDeviceMapper.updateSlopeVideoDevice(slopeVideoDevice);
    }

    /**
     * 批量删除视频设备列表
     * 
     * @param ids 需要删除的视频设备列表主键
     * @return 结果
     */
    @Override
    public int deleteSlopeVideoDeviceByIds(Long[] ids)
    {
        return slopeVideoDeviceMapper.deleteSlopeVideoDeviceByIds(ids);
    }

    /**
     * 删除视频设备列表信息
     * 
     * @param id 视频设备列表主键
     * @return 结果
     */
    @Override
    public int deleteSlopeVideoDeviceById(Long id)
    {
        return slopeVideoDeviceMapper.deleteSlopeVideoDeviceById(id);
    }
}
